package com.jt.vo;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import lombok.experimental.Accessors;

@Data
@Accessors(chain = true)
@NoArgsConstructor
@AllArgsConstructor
public class SysResult {
    private Integer status;//200成功 201失败
    private String message;
    private Object data;
    public static SysResult fail(){
        return new SysResult(201,"泥缪的，错了",null);
    }
    public static SysResult success(Object data){
        return new SysResult(200,"你真腻害，成功拉",data);
    }
    public static SysResult success(){
        return new SysResult(200,"你真腻害，成功拉",null);
    }
    public static SysResult success(String message,Object data){
        return new SysResult(200,message,data);
    }
}
